/**
 * 数组
 */
let array:number[] = [1,2,3]
let array2:string[] = ["xiaowang"]

let array3:Array<{id:number,name:string}> = [{id:1,name:"xiaowang"}]


/**
 * 枚举
 */
enum orderState {
    error=0,
    success=1,
    timeout=2
}
const order = {
    id:1,
    name:"团购订单",
    state:1
}
if(order.state == orderState.error){
    //失败代码
}else if(order.state === orderState.success){

}

/**
 * undefined null
 * 联合类型
 */
let stu:number | undefined | null;
console.log(stu);
stu = 1
stu = null


/**
 * object类型
 */
let user:object = {id:1}
let user2:object = []
let user3:object = function(){}

// console.log(user.id);
let user4:{id:number} = {id:1}
console.log(user4.id);

/**
 * any
 */
 let stuName:any = "xiaowang"
 stuName = 1
 


//暴露，默认采用了模块化。
export {}